const { resolve } = require('path')
let path=require('path')
function reslove(dir) {
    return path.join(__dirname, dir)
}
module.exports = {
    chainWebpack: config => {
        // set alias
        config.resolve.alias
        .set('@', resolve('src'))
        .set("@assets", resolve("src/assets"));
    },
    devServer: {
        open: true
    },
    // scss global variable
    css: {
        loaderOptions: {
            sass: {
                data: `@import "@/assets/scss/global.scss";`
            }
        }
    }
}